namespace Traceability.API.Config
{
    /// <summary>
    /// 七牛云配置选项
    /// </summary>
    public class QiNiuOptions
    {
        /// <summary>
        /// AccessKey
        /// </summary>
        public string AccessKey { get; set; } = string.Empty;

        /// <summary>
        /// SecretKey
        /// </summary>
        public string SecretKey { get; set; } = string.Empty;

        /// <summary>
        /// 存储空间名称
        /// </summary>
        public string Bucket { get; set; } = string.Empty;

        /// <summary>
        /// 访问域名
        /// </summary>
        public string BaseUrl { get; set; } = string.Empty;

        /// <summary>
        /// 存储区域
        /// </summary>
        public string Zone { get; set; } = "CN_North";

        /// <summary>
        /// 是否使用HTTPS
        /// </summary>
        public bool UseHttps { get; set; } = true;

        /// <summary>
        /// 是否使用CDN域名
        /// </summary>
        public bool UseCdnDomains { get; set; } = true;

        /// <summary>
        /// 分片上传块大小(KB)
        /// </summary>
        public int ChunkSize { get; set; } = 512;

        /// <summary>
        /// 上传凭证有效期(秒)
        /// </summary>
        public int TokenExpires { get; set; } = 3600;

        /// <summary>
        /// 文件自动删除天数(null表示不自动删除)
        /// </summary>
        public int? DeleteAfterDays { get; set; }

        /// <summary>
        /// 允许的文件类型
        /// </summary>
        public List<string> AllowedFileTypes { get; set; } = new List<string>();

        /// <summary>
        /// 最大文件大小(MB)
        /// </summary>
        public int MaxFileSizeMB { get; set; } = 10;
    }
}
